<?php include './application/views/top.php'; ?>
<script src="/static/js/ajaxfileupload.js"></script>
<script src="/static/js/gsdai.js"></script>
<script src="/static/js/My97DatePicker/WdatePicker.js"></script>
<script src="/static/js/formCheck.js"></script>
<div class="clear"></div>
<div class="user_bottom all"></div>
<div class="clear h50"></div>
<div class="layout uc">
	<?php include './application/views/user/left.php'; ?>
	<?php
		$sex = $v['sex'];
		$cardType = $v['cardType'];
	?>
	<div class="right">
		<div class="menu_list"><?php include './application/views/user/menu.php'; ?></div>
        <div class="clear h30"></div>
        <div class="tishi" style="font-size:14px; font-weight:normal;">
        共完成提现<?php echo number_format($sum_money['total']?$sum_money['total']:0,2);?>元，到账<?php echo number_format($sum_money['credited']?$sum_money['credited']:0,2);?>元，提现手续费<?php echo number_format($sum_money['fee']?$sum_money['fee']:0,2);?>元
        </div>
        <div class="cont">
        	<ul class="tbt">
            	<li class="w120">提现总额</li>
                <li class="w120">到账金额</li>
                <li class="w120">手续费</li>
                <li class="w160">提现时间</li>
                <li class="w160">订单号</li>
                <li class="w120">状态</li>
                <li class="w118 npr">操作</li>
            </ul>
            <?php foreach($list as $val){?>
        	<ul class="tbc">
            	<li class="w120">&yen;<?php echo number_format($val['total'],2);?>/li>
                <li class="w120">&yen;<?php if($val['fstatus'] == 4){?><?php echo number_format($val['credited'],2);?><?php }else{?>0.00<?php }?></li>
                <li class="w120">&yen;<?php echo number_format($val['fee'],2);?></li>
                <li class="w160"><?php echo date('Y-m-d H:i',$val['add_time']);?></li>
                <li class="w160"><?php echo $val['mmm_loanno'];?></li>
                <li class="w120"><?php echo $cash_status[$val['fstatus']];?></li>
                <li class="w118 npr"><?php if($val['fstatus'] == 0){?><a href="javascript:void(0);" onclick="cancel('<?php echo $val['id'];?>');">取消</a><?php }?></li>
            </ul>
            <?php }?>        
        </div>
        <div class="clear h30"></div>
        <div class="page">
            <div class="pagination">
            <?php echo $this->pagination->create_links();?>
            </div>
        </div>
	</div>
</div>
<div class="clear h50"></div>
<?php include "./application/views/footer.php";?>

<table width="90%" cellspacing="0" cellpadding="0" border="0" class="user_table" style="width:1000px;margin:50px auto;">
	<tr>
		<td valign="top" class="user_table_td"><?php include './application/views/common/user_left.php'; ?></td>
		<!-- Left End -->
		<td valign="top">

<div class="user_list_title">
 <?php include './application/views/common/user_sub_left.php'; ?>
</div>
<!-- User_List_Title End -->
<div class="user_list_con">
	<div class="user_list_search"><form id="tmpform"></form></div>
	<div class="user_list_con">
		<table width="100%" border="0" cellspacing="0" cellpadding="0">
		  
		  <tr height="35px">
			<td align="center"></td>
			<td align="center"> </td>
			<td align="center"></td>
			<td align="center"></td>
			<td align="center"></td>
			<td align="center"></td>
			<td align="center"> </td>
		  </tr>
		  
		  <tr>
		  	<td align="center" colspan="8" class="page"><?php echo $this->pagination->create_links();?></td>
		  </tr>
		</table>
	
	</div>

<script>
function cancel(id){
	var options = {
		url : '/account/cash_cancel/'+id,
		dataType: "json",
		type:"get",
		success : function(ret) {
			$('#dialog').dialog({
				modal:true,
				title:'系统提示',
				buttons:{"确定":function(){$(this).dialog("close");}},
				close: function() {
					if(ret.url==''){
						window.location.reload();
					}else{
						location=ret.url;
					}
				}
			}); 
			$("#msg").html(ret.msg);
		}
	};
	$('#tmpform').ajaxSubmit(options);
	return false;
}
</script>
<!-- User_List_Con End -->
</td>
	</tr>
</table>

<?php include './application/views/common/footer.php'; ?>